package servlet;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import DAO.UserDao;

public class MemberIDCheckAction implements Action {

	@Override
	public ActionForward execute(HttpServletRequest request,
			HttpServletResponse response) throws Exception {
	
		ActionForward forward=new ActionForward();
		String memid=request.getParameter("memid");
		
		UserDao userDao = new UserDao();
		boolean check = userDao.isCheckedDuplicatedId(memid);
		
		request.setAttribute("memid", memid);
		request.setAttribute("check", check);
		
		forward.setPath("./member_idchk.jsp");
		
		
		return forward;
	}

}
